package com.kool.evowkf.bean.io.approve;

import com.kool.core.base.BaseBean;
import com.kool.core.exception.AppException;
import com.kool.core.validate.IIoValidate;

/**
 * @AUTHOR LUYU
 */
public class CMQRYSCHEDULEXBean extends BaseBean implements IIoValidate {
	protected String wkfNbr;
	protected String lastUserCid;
	protected String state;
	protected String businessType;

	/**
	 * @return the businessType
	 */
	public String getBusinessType() {
		return businessType;
	}

	/**
	 * @param businessType
	 *            the businessType to set
	 */
	public void setBusinessType(String businessType) {
		this.businessType = businessType;
	}

	public String getWkfNbr() {
		return wkfNbr;
	}

	public void setWkfNbr(String wkfNbr) {
		this.wkfNbr = wkfNbr;
	}

	public String getLastUserCid() {
		return lastUserCid;
	}

	public void setLastUserCid(String lastUserCid) {
		this.lastUserCid = lastUserCid;
	}

	public String getState() {
		return state;
	}

	public void setState(String state) {
		this.state = state;
	}

	@Override
	public void validate() throws AppException {
		// 最大长度校验
		if (wkfNbr != null && wkfNbr.length() > 16) {
			throw new AppException("SY000038", "wkfNbr", String.valueOf(16));// 字段[%1]大于最大长度[%2]
		}
		// 最大长度校验
		if (lastUserCid != null && lastUserCid.length() > 10) {
			throw new AppException("SY000038", "lastUserCid", String.valueOf(10));// 字段[%1]大于最大长度[%2]
		}
	}
}